package com.itheima.arrayDemo1;

public class arrayDemo2 {
    public static void main(String[] args) {
        //数组的索引
        //从0开始
        //1.获取数组中的元素
        int[] arr = {1,2,3,4,5};
        int number = arr[0];
        System.out.println(number);
        System.out.println(arr[1]);

        //2.把数据存在数组中
        arr[0] = 100;
        System.out.println(arr[0]);
    }
}
